from openai import OpenAI

client = OpenAI(
    base_url='https://ms-fc-3a4b406c-126c.api-inference.modelscope.cn/v1',
    api_key='ms-a8f26506-6c3c-46be-9374-a7fec25eca9c', # ModelScope Token
)

response = client.embeddings.create(
    model='Qwen/Qwen3-Embedding-8B-GGUF', # ModelScope Model-Id, required
    input='你好',
    encoding_format="float"
)

print(response)